<template>
    <div class="order-report-wrapper" style="height: 100%">
        <div style="height: 100%">
            <iframe
                class="service"
                :src="url"
                width="100%"
                height="100%"
            ></iframe>
        </div>
    </div>
</template>

<script type="text/ecmascript-6">
export default {
    data: function () {
        return {
            activeName: '1',
            url: ''
        }
    },
    mounted () { },
    created () {
        if (this.roleId === 1) {
            this.url = this.LeisureUrl + 'leisureManager/#/mainPage?IsImplant=1&roleId=1&manageRoleType=' + this.manageRoleType + '&routeAddress=reconCiliation' + '&loginToken=' + localStorage.AuthorizationToken2
        } else {
            this.url = this.LeisureUrl + 'leisureManager/#/mainPage?IsImplant=1&roleId=2&agentName=' + encodeURIComponent(this.userName) + '&smsToken=' + this.smsToken + '&routeAddress=reconCiliation' + '&loginToken=' + localStorage.AuthorizationToken2
        }
    },
    watch: {},
    components: {
    },
    props: {
        underLine: null
    },
    computed: {
        roleId () {
            return this.$store.state.roleId
        },
        userName () {
            return this.$store.state.userName
        },
        LeisureUrl () {
            return this.$store.state.LeisureUrl
        },
        smsToken () {
            return this.$store.state.smsToken
        },
        manageRoleType () {
            return this.$store.state.manageRoleType
        }
    },
    methods: {
        // 换页方法
        handleCurrentChange (val) {
            this.position = val
        }
    }
}
</script>

<style lang="stylus" rel="stylesheet/stylus">
.el-tabs__nav-wrap::after
    content: ''
    position: absolute
    left: 0
    bottom: 0
    width: 100%
    height: 1px
    background-color: #e4e7ed
    z-index: 1

.el-tabs__nav-scroll
    padding: 0 22px

.service
    height: -webkit-fill-available

.order-report-wrapper
    width: 100%

    .order-report-wrapper-title
        width: 100%
        height: 40px
        font-size: 14px
        line-height: 30px
        padding-left: 22px
</style>
